home *** CD-ROM | disk | FTP | other *** search
- Path: newsfeed.internetmci.com!panix!cmcl2!news!schonberg!dewar
- From: dewar@cs.nyu.edu (Robert Dewar)
- Newsgroups: comp.lang.ada,comp.lang.c,comp.lang.c++,comp.edu
- Subject: Re: C/C++ knocks the crap out of Ada
- Date: 26 Mar 1996 08:26:47 -0500
- Organization: Courant Institute of Mathematical Sciences
- Message-ID: <dewar.827846475@schonberg>
- References: <JSA.96Feb16135027@organon.com> <4ikbar$g0k@tpd.dsccc.com> <adaworksDoL573.7vs@netcom.com> <JSA.96Mar21160427@organon.com> <4iupk7$5t4@tpd.dsccc.com> <JSA.96Mar25205417@organon.com>
- NNTP-Posting-Host: schonberg.cs.nyu.edu
- X-Newsreader: NN version 6.5.0 (NOV)
-
- "A Thompson guy could better answer this. I would be surprised
- if Gnat and ObjectAda didn't compile things with little or no
- modification. Heck, I've taken large chuncks of VAX Ada and moved
- them to Gnat with no changes. Of course, these did not have any
- OS specific stuff in them."
-
- That should be true providing you stick to the subset of the language in
- terms of annexes that ObjectAda implements. GNAT is the only Ada 95
- compiler so far that implements all the annexes, so if you take advantage
- of this, your code will not be easily portable to other compilers not
- supprting these annexes.
-
- Moving large chunks of VAX Ada is not a test, since that is Ada 83 code.
-
- The question was whether GNAT code can be moved to ObjectAda. Note also
- that GNAT implements a number of implementatoin dependent pragmas
- and attributes. If you are using any of these, you will have to check
- whether the other compiler does too. FOr example, if you are using the
- pragmas to provide interoperability between C++ classes and Ada tagged
- types, you may have a hard time moving your code. Not only may the pragmas
- not exist, but there simply may be no such interoperability, since it is
- not rquired by the standard.
-
- As always, if you want to write highly portable code, stay away from
- implementation dependent features, and make sure the compilers support
- the same feature sets.
-
- Of course porting code from one GNAT implementation to another is much
- less of a problem, and since GNAT is available on many platforms, with
- more being added all the time, this form of portability will be enough
- for many users of Ada 95 :-)
-
- Robert Dewar
- Ada Core Technologies
-
-